<template>
    <div id="app">
        <div class="index">
            <MainNav  class="mainnav" v-if="!isLoginRoute"></MainNav>
            <div class="right">
                <!-- <BreadNav class="breadnav" v-if="!isLoginRoute">
                    <template #breadnav>22</template>
                </BreadNav> -->
                <router-view class="main"></router-view>
            </div>
        </div>
    </div>
</template>

<script>
import BreadNav from "./components/BreadNav";
import MainNav from "./components/MainNav.vue";

export default {
    name: "App",
    components: {
        MainNav,
        BreadNav,
        MainNav,
    },
    computed:{
        isLoginRoute(){
            return this.$route.path ==='/'
        }
    },
    methods: {
        navigateTo(path){
            console.log(11,path);
        },
    }
};
</script>

<style scoped>
.mainnav {
    position: fixed !important;
    top: 0;
    left: 0;
    z-index: 3;
}
.breadnav {
    position: fixed;
    top: 0;
    left: 186px;
    z-index: 1;
    background-color: #fff;
}
body {
    padding: 0;
    margin: 0;
}
#app {
    /* overflow-x: hidden; */
    padding: 0;
    margin: 0;
    box-sizing: border-box;
}
.el-menu-item {
    width: 186.3px !important;
    box-sizing: border-box !important;
}
.el-submenu .el-menu-item {
    height: 50px;
    line-height: 50px;
    padding: 0 45px;
    min-width: 186.3px !important;
    box-sizing: border-box;
}
.index {
    position: relative;
}
.right {
    position: absolute;
    top: 0;
    left: 189px;
    z-index: 1;
}
.title {
    height: 50px;
    line-height: 50px;
    box-sizing: border-box;
    background-color: #434343;
    color: #f0f0f0;
    text-align: center;
    font-size: 16px;
    width: 186.9px;
}
.nav {
    /* position: fixed;
    top: 0;
    left: 210px; */
    width: 1300px;
    /* width: 100%; */
    display: flex;
    height: 50px;
    line-height: 0;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
    box-sizing: border-box;
}
.nav-right {
    display: flex;
}
.headphone {
    width: 22px;
    height: 21px;
    margin-right: 30px;
}
.alarm {
    width: 21px;
    height: 24px;
    margin-right: 55px;
}
.avatar {
    width: 27px;
    height: 27px;
    border-radius: 50%;
    margin-right: 10px;
}
.name {
    font-size: 13px;
    color: #333;
}
.menu {
    background-color: #f5f5f5;
    padding: 50px 30px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    height: 100%;
}
.menu-item {
    width: 400px;
    height: 104px;
    border-radius: 5px;
    background-color: #fff;
    display: flex;
    align-items: center;
    margin: 10px 0;
}
.icon {
    width: 50px;
    height: 50px;
    margin-right: 20px;
    padding: 0 40px;
    box-sizing: border-box;
}
.main {
    background-color: #f5f5f5;
    padding: 20px 20px;
    box-sizing: border-box;
    /* height: 100vh; */
    /* width: 110%; */
}
</style>
